import { Injectable } from '@angular/core';
import {RequestUtil} from "../../../util/request-util";
import {Observable} from "rxjs/Observable";
import {MsgResult} from "../../../models/msg-result";
import {API} from "../../../constants/constants";

@Injectable()
export class DeviceService {

  constructor(
    private requestUtil: RequestUtil
  ) { }


  /**
   *
   * @param origin
   * @returns {Observable<MsgResult>}
   */
  // getDeviceStatusData(origin: any): Observable<MsgResult> {
  //   let params = "deviceType=" + origin.sites + "&startTimeStr=" + origin.startTime + "&endTimeStr=" + origin.endTime;
  //   return this.requestUtil.get(API.getDeviceStatusCondition, params);
  // }

  /**
   *  获取行政区划省，市，县(区) 三级行政区划树(get请求)
   *  <p> 1.用于数据表查询   -> 数据表格
   *                         -> 数据图表 站点选择中行政区划树的初始化
   * @returns {Observable<MsgResult>}
   */
  // getThreeLevelRegionTree():Observable<MsgResult>{
  //   let params = "&regionCode="+'0';
  //   return this.requestUtil.get(API.getThreeLevelRegionTree,params);
  // }
}
